home *** CD-ROM | disk | FTP | other *** search
/ The World of Computer Software / The World of Computer Software.iso / psd.zip / PSD.SCM < prev    next >
Text File  |  1992-07-09  |  3KB  |  76 lines

  1. ;;;;
  2. ;;;; psd.scm 1.3
  3. ;;;;
  4. ;;;; psd -- a portable Scheme debugger, version 1.0
  5. ;;;; Copyright (C) 1992 Pertti Kellomaki, pk@cs.tut.fi
  6.  
  7. ;;;; This program is free software; you can redistribute it and/or modify
  8. ;;;; it under the terms of the GNU General Public License as published by
  9. ;;;; the Free Software Foundation; either version 1, or (at your option)
  10. ;;;; any later version.
  11.  
  12. ;;;; This program is distributed in the hope that it will be useful,
  13. ;;;; but WITHOUT ANY WARRANTY; without even the implied warranty of
  14. ;;;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
  15. ;;;; GNU General Public License for more details.
  16.  
  17. ;;;; You should have received a copy of the GNU General Public License
  18. ;;;; along with this program; if not, write to the Free Software
  19. ;;;; Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
  20. ;;;; See file COPYING in the psd distribution.
  21.  
  22. ;;;; 
  23. ;;;; Written by Pertti Kellomaki, pk@cs.tut.fi
  24. ;;;;
  25. ;;;; SLIB interface to load psd files.
  26.  
  27. ;;;; This is the file that takes care of loading psd into the Scheme
  28. ;;;; interpreter. If you want to modify psd to work with a particular
  29. ;;;; implementation, say "foo", this is the way to do it:
  30.  
  31. ;;;; 1) Make a copy of the file "psd.scm" under the name "psd-foo.scm",
  32. ;;;;    and modify it to load "primitives-foo.scm" instead of
  33. ;;;;    "primitives.scm". You can also do other things.
  34. ;;;;
  35. ;;;; 2) Make a copy of the file "primitives.scm" under the name
  36. ;;;;    "primitives-foo.scm", and modify the definitions in it to
  37. ;;;;    know about the additional primitives in your implementation
  38. ;;;;
  39. ;;;; 3) When you now set the Emacs variable scheme-program-name to
  40. ;;;;    "foo" and give the commands ``M-x run-scheme'' ``M-x psd-mode'',
  41. ;;;;    you have a psd system that knows about your additional
  42. ;;;;    primitives.
  43.  
  44. ;;; this is not portable.
  45. (define psd:control-z (integer->char 26))
  46.  
  47. ;;; FORCE-OUTPUT flushes any pending output on optional arg output port
  48. ;;; use this definition if your system doesn't have such a procedure.
  49. (define (force-output . arg) #t)
  50.  
  51. ;;; If you are using slib, use the following.
  52. ;(load (in-vicinity (program-vicinity) "instrum" (scheme-file-suffix)))
  53. ;(load (in-vicinity (program-vicinity) "pexpr" (scheme-file-suffix)))
  54. ;(load (in-vicinity (program-vicinity) "read" (scheme-file-suffix)))
  55. ;(load (in-vicinity (program-vicinity) "runtime" (scheme-file-suffix)))
  56. ;(load (in-vicinity (program-vicinity) "primitives" (scheme-file-suffix)))
  57.  
  58. ;;; If you are not using slib, use the following instead.
  59.  
  60. (define psd-directory "/usr/local/lib/psd/")
  61. (load (string-append psd-directory "instrum.scm"))
  62. (load (string-append psd-directory "pexpr.scm"))
  63. (load (string-append psd-directory "read.scm"))
  64. (load (string-append psd-directory "runtime.scm"))
  65. (load (string-append psd-directory "primitives.scm"))
  66.  
  67. ;;;;
  68. ;;;; Some implementations have variables that control how long and how
  69. ;;;; deep lists are printed. If you are using psd with a Scheme that
  70. ;;;; is not supported and you are having problems, this is a
  71. ;;;; potential cause.
  72. ;;;;
  73.  
  74. ;(set! print-length -1)
  75. ;(set! print-depth -1)
  76.